<script>
    var router_url = "<?php echo Router::url(array('controller'=>'calendar','action'=>'calendar'));?>";
    
    function routerUrl(controller, action, parameters)
    {
        full_url = "http://localhost"+router_url+"/"+controller+"/"+action+"/"+parameters;
        return full_url;
    }
    
    function abrePagina(url)
    {
        $.ajax({
            cache: false,
            type: 'GET',
            dataType: 'HTML', 
            url: url,
            data: { name: "John", location: "Boston" }
            }).done(function( msg ) {
                $('.alvo').html(msg);
        });
    }

    $(document).ready(function(){
        abrePagina(routerUrl('pages','edit',1));
    });
</script>

<section id="typography">
  <div class="page-header">
    <h1>Gerenciador <small>páginas, fotos, vídeos, agenda e o conteúdo que precisar</small></h1>
  </div>
    
    <?php echo $this->element('_admin/management_menu'); ?>

  <!-- Headings & Paragraph Copy -->
    <div class="row">
        <?php echo $this->element('_admin/events/management_side'); ?>

        <div class="span9">
            <h3>sua agenda</h3>
            <?php echo $this->element('_admin/flash_messages'); ?>
            <div class="alvo"></div>
        </div>
    </div>
</section>